<template>
  <div class="ddei-experience-panel-goback">
    <div class="header"></div>
    <div class="content">
      <div class="goback">
        <div class="out">
          <svg class="icon" aria-hidden="true" @click="goBackFileList">
            <use xlink:href="#icon-a-ziyuan476"></use>
          </svg>
        </div>
      </div>
      <div class="logo">
        <img src="/src/assets/images/logo.png">
      </div>
    </div>
    <div class="tail">
    </div>
  </div>
</template>
<script lang="ts">
import {DDeiEditor} from "ddei-editor";
import {DDeiEditorUtil} from "ddei-editor";

export default {
  name: "ddei-experience-panel-goback",
  extends: null,
  mixins: [],
  props: {
    //外部传入的插件扩展参数
    options: {
      type: Object,
      default: null
    }
    , editor: {
      type: DDeiEditor,
      default: null,
    }
  },
  data() {
    return {
      file: {},
      fileNameEditing: false,
      fileDescEditing: false
    };
  },
  computed: {},
  watch: {},
  created() { },
  mounted() {
    //获取编辑器
    this.file = this.editor?.files[this.editor?.currentFileIndex];
  },
  methods: {

    /**
     * 返回文件列表页
     */
    goBackFileList() {
      this.$router.push({
        path: "/",
      });
    },

  },
};
</script>

<style lang="less" scoped>
.ddei-experience-panel-goback {
  height: 103px;
  width: 120px;
  flex:0 1 120px;
  display: grid;
  grid-template-rows: 20px 57px 26px;
  grid-template-columns: 1fr;

  .content {
    display: flex;
    justify-content: center;
    align-items: center;
    border-right: 1px solid var(--panel-border);//darken(var(--panel-header), 13%);

    .goback {
      flex: 0 1 36px;
      display: flex;
      justify-content: center;
      align-items: center;

      .out {
        flex: 0 0 25px;
        height: 36px;
        background: var(--panel-header);//darken(var(--panel-header), 5%);
        border-radius: 2px;
        display: flex;
        justify-content: center;
        align-items: center;

        >svg:hover {
          filter: brightness(200%);
          cursor: pointer;
        }
      }


    }

    .logo {
      flex: 0 1 75px;
      display: flex;
      justify-content: center;
      align-items: center;

      >img {
        width: 65px;
        height: 65px;
      }
    }
  }

  .tail {
    border-right: 1px solid var(--panel-border);//darken(var(--panel-header), 13%);
  }
}
</style>
